package com.bdqn.jd;

import org.junit.jupiter.api.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;


public class TestPlayer {
    @Test
    public void test(){
        ApplicationContext context=new ClassPathXmlApplicationContext("equip.xml");
        Player player=(Player) context.getBean("player");
        Equip equip = new Equip();
        equip.setName(player.getRing().getName());
        equip.setType(player.getRing().getType());
        equip.setAttackPlus(player.getRing().getAttackPlus());
        equip.setDefencePlus(player.getRing().getDefencePlus());
        player.updateEquip(equip);
    }
}
